package com.antdesignbackend.backend.service.impl;

import com.antdesignbackend.backend.entity.MonthReportRecord;
import com.antdesignbackend.backend.entity.entityVo.MonthReportRecordVo;
import com.antdesignbackend.backend.mapper.MonthReportRecordMapper;
import com.antdesignbackend.backend.service.MonthReportRecordService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.apache.ibatis.annotations.Param;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class MonthReportRecordServiceImpl extends ServiceImpl<MonthReportRecordMapper, MonthReportRecord> implements MonthReportRecordService {
    @Autowired
    MonthReportRecordMapper monthReportRecordMapper;
    @Override
    public List<MonthReportRecordVo> search(@Param(Constants.WRAPPER) QueryWrapper<MonthReportRecordVo> monthReportRecordVoQueryWrapper, Page<MonthReportRecordVo> monthReportRecordVoPage){
        return monthReportRecordMapper.search(monthReportRecordVoQueryWrapper,monthReportRecordVoPage);
    };
    @Override
    public Integer count(@Param(Constants.WRAPPER) QueryWrapper<MonthReportRecordVo> monthReportRecordVoQueryWrapper){
        return monthReportRecordMapper.count(monthReportRecordVoQueryWrapper);
    };
}
